/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package models;


import tableModels.TableEtapeModel;
import utils.TableModel;
import java.sql.SQLException;
import java.util.logging.Level;
import java.util.logging.Logger;

/**
 *
 * @author juju
 */
public class Etape {
    protected int _Identifiant;
    protected int _IdentifiantCircuit;
    protected int _Ordre;
    protected String _NomLieu;
    protected String _Ville;
    //protected String _Pays;
    protected String _DateEtape;
    protected int _Duree;
    private EtapeMapper mapper;
    
    public Etape() {
        this.mapper = new EtapeMapper();
    }

    public int getIdentifiantCircuit() {
        return _IdentifiantCircuit;
    }

    public void setIdentifiantCircuit(int _IdentifiantCircuit) {
        this._IdentifiantCircuit = _IdentifiantCircuit;
    }

    public int getOrdre() {
        return _Ordre;
    }

    public void setOrdre(int _Ordre) {
        this._Ordre = _Ordre;
    }

    public String getNomLieu() {
        return _NomLieu;
    }

    public void setNomLieu(String _NomLieu) {
        this._NomLieu = _NomLieu;
    }

    public String getVille() {
        return _Ville;
    }

    public void setVille(String _Ville) {
        this._Ville = _Ville;
    }
    public int getIdentifiant() {
        return _Identifiant;
    }

    public void setIdentifiant (int _Identifiant) {
        this._Identifiant = _Identifiant;
        
    }
    /*public String getPays() {
        return _Pays;
    }

    public void setPays(String _Pays) {
        this._Pays = _Pays;
    }*/

    public String getDateEtape() {
        return _DateEtape;
    }

    public void setDateEtape(String _DateEtape) {
        this._DateEtape = _DateEtape;
    }

    public int getDuree() {
        return _Duree;
    }

    public void setDuree(int _Duree) {
        this._Duree = _Duree;
    }
    
      public void find(int id) {
        try {
            this.mapper.find(id, this);
        } catch (SQLException ex) {
            Logger.getLogger(Client.class.getName()).log(Level.SEVERE, null, ex);
        }
    }
    
      public TableEtapeModel fetchAll() {
        return mapper.fetchAll();
    }
}
